/**
 * Copyright (c) 2014, 2016 itemis AG (http://www.itemis.eu) and others.
 * This program and the accompanying materials are made available under the
 * terms of the Eclipse Public License 2.0 which is available at
 * http://www.eclipse.org/legal/epl-2.0.
 * 
 * SPDX-License-Identifier: EPL-2.0
 */
package org.eclipse.xtend.core.tests.compiler;

import org.eclipse.xtend2.lib.StringConcatenation;
import org.junit.Ignore;
import org.junit.Test;

/**
 * @author Sebastian Zarnekow - Initial contribution and API
 */
@SuppressWarnings("all")
public class CompilerBug435473Test extends AbstractXtendCompilerTest {
  @Test
  public void test_01() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<Functions.Function0<?>> x = #[[|1],  [|1.0]]");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<Function0<?>> x = Collections.<Function0<?>>unmodifiableList(CollectionLiterals.<Function0<?>>newArrayList(new Function0<Object>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Object apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Integer.valueOf(1);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Object>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Object apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Double.valueOf(1.0);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_02() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<Functions.Function0<? extends Number>> x = #[[|1],  [|1.0]]");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<Function0<? extends Number>> x = Collections.<Function0<? extends Number>>unmodifiableList(CollectionLiterals.<Function0<? extends Number>>newArrayList(new Function0<Number>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Number apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Integer.valueOf(1);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Number>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Number apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Double.valueOf(1.0);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_03() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<? extends Functions.Function0<? extends Number>> x = #[[|1],  [|1.0]]");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<? extends Function0<? extends Number>> x = Collections.<Function0<? extends Number>>unmodifiableList(CollectionLiterals.<Function0<? extends Number>>newArrayList(new Function0<Number>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Number apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Integer.valueOf(1);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Number>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Number apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Double.valueOf(1.0);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_04() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<? extends Functions.Function0<Number>> x = #[[|1],  [|1.0]]");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<? extends Function0<Number>> x = Collections.<Function0<Number>>unmodifiableList(CollectionLiterals.<Function0<Number>>newArrayList(new Function0<Number>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Number apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Integer.valueOf(1);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Number>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Number apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Double.valueOf(1.0);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_05() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.Set");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val Set<Functions.Function0<? extends Number>> x = #{ [|1],  [|1.0] }");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.Set;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final Set<Function0<? extends Number>> x = Collections.<Function0<? extends Number>>unmodifiableSet(CollectionLiterals.<Function0<? extends Number>>newHashSet(new Function0<Number>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Number apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Integer.valueOf(1);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Number>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Number apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Double.valueOf(1.0);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_06() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.Set");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val Set<Functions.Function0<Number>> x = #{ [|1],  [|1.0] }");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.Set;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final Set<Function0<Number>> x = Collections.<Function0<Number>>unmodifiableSet(CollectionLiterals.<Function0<Number>>newHashSet(new Function0<Number>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Number apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Integer.valueOf(1);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Number>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Number apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Double.valueOf(1.0);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_07() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.Set");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val Set<? extends Functions.Function0<? extends Number>> x = #{ [|1],  [|1.0] }");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.Set;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final Set<? extends Function0<? extends Number>> x = Collections.<Function0<? extends Number>>unmodifiableSet(CollectionLiterals.<Function0<? extends Number>>newHashSet(new Function0<Number>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Number apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Integer.valueOf(1);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Number>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Number apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Double.valueOf(1.0);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_08() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.Set");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val Set<? extends Functions.Function0<Number>> x = #{ [|1],  [|1.0] }");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.Set;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final Set<? extends Function0<Number>> x = Collections.<Function0<Number>>unmodifiableSet(CollectionLiterals.<Function0<Number>>newHashSet(new Function0<Number>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Number apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Integer.valueOf(1);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Number>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Number apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Double.valueOf(1.0);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_09() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<Functions.Function0<?>> x = newArrayList([|1],  [|1.0])");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<Function0<?>> x = CollectionLiterals.<Function0<?>>newArrayList(new Function0<Integer>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Integer apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Integer.valueOf(1);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Double>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Double apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Double.valueOf(1.0);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("});");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_10() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<Functions.Function0<? extends Number>> x = newArrayList([|1],  [|1.0])");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<Function0<? extends Number>> x = CollectionLiterals.<Function0<? extends Number>>newArrayList(new Function0<Integer>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Integer apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Integer.valueOf(1);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Double>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Double apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Double.valueOf(1.0);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("});");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_11() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<? extends Functions.Function0<? extends Number>> x = newArrayList([|1],  [|1.0])");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<? extends Function0<? extends Number>> x = CollectionLiterals.<Function0<? extends Number>>newArrayList(new Function0<Integer>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Integer apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Integer.valueOf(1);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Double>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Double apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Double.valueOf(1.0);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("});");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  @Ignore("Would be nice but too much effort ATM")
  public void test_12() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<? extends Functions.Function0<Number>> x = newArrayList([|1],  [|1.0])");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("IGNORED");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_13() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val x = #[[|1],  [|1.0]]");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<? extends Function0<? extends Number>> x = Collections.<Function0<? extends Number>>unmodifiableList(CollectionLiterals.<Function0<? extends Number>>newArrayList(new Function0<Integer>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Integer apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Integer.valueOf(1);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Double>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Double apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Double.valueOf(1.0);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_14() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val x = newArrayList([|1],  [|1.0])");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.ArrayList;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final ArrayList<Function0<? extends Number>> x = CollectionLiterals.<Function0<? extends Number>>newArrayList(new Function0<Integer>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Integer apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Integer.valueOf(1);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Double>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Double apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Double.valueOf(1.0);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("});");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_15() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<? extends Functions.Function0<Number>> x = <Functions.Function0<Number>>newArrayList([|1],  [|1.0])");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<? extends Function0<Number>> x = CollectionLiterals.<Function0<Number>>newArrayList(new Function0<Number>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Number apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Integer.valueOf(1);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Number>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Number apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Double.valueOf(1.0);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("});");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_16() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.Map");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val Map<String, Functions.Function0<?>> y = #{\'\' -> [|1], \'\' -> [|1.0]}");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.Map;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Pair;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final Map<String, Function0<?>> y = Collections.<String, Function0<?>>unmodifiableMap(CollectionLiterals.<String, Function0<?>>newHashMap(Pair.<String, Function0<Integer>>of(\"\", new Function0<Integer>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Integer apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Integer.valueOf(1);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}), Pair.<String, Function0<Double>>of(\"\", new Function0<Double>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Double apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Double.valueOf(1.0);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("})));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_17() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.Map");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val Map<CharSequence, Functions.Function0<?>> y = #{null as StringBuilder -> [|1], null as StringBuffer -> [|1.0]}");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.Map;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Pair;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final Map<CharSequence, Function0<?>> y = Collections.<CharSequence, Function0<?>>unmodifiableMap(CollectionLiterals.<CharSequence, Function0<?>>newHashMap(Pair.<StringBuilder, Function0<Integer>>of(((StringBuilder) null), new Function0<Integer>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Integer apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Integer.valueOf(1);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}), Pair.<StringBuffer, Function0<Double>>of(((StringBuffer) null), new Function0<Double>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Double apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return Double.valueOf(1.0);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("})));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_18() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val x = newArrayList( String.CASE_INSENSITIVE_ORDER, [ $0 <=> $1 ] )");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.ArrayList;");
    _builder_1.newLine();
    _builder_1.append("import java.util.Comparator;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final ArrayList<Comparator<?>> x = CollectionLiterals.<Comparator<?>>newArrayList(String.CASE_INSENSITIVE_ORDER, new Comparator<Comparable<? super Comparable<?>>>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public int compare(final Comparable<? super Comparable<?>> $0, final Comparable<? super Comparable<?>> $1) {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ($0.compareTo($1));");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("});");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_19() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val x = newArrayList( String.CASE_INSENSITIVE_ORDER, [ String s1, s2| s1 <=> s2 ] )");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.ArrayList;");
    _builder_1.newLine();
    _builder_1.append("import java.util.Comparator;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final ArrayList<Comparator<String>> x = CollectionLiterals.<Comparator<String>>newArrayList(String.CASE_INSENSITIVE_ORDER, new Comparator<String>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public int compare(final String s1, final String s2) {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return (s1.compareTo(s2));");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("});");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_20() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import static org.junit.Assert.*");
    _builder.newLine();
    _builder.append("import static org.hamcrest.CoreMatchers.*");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("def void m() {");
    _builder.newLine();
    _builder.append("\t\t");
    _builder.append("assertThat(#[1, 2.0, 3], hasItem(5))");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("}");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.hamcrest.CoreMatchers;");
    _builder_1.newLine();
    _builder_1.append("import org.junit.Assert;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public void m() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("Assert.<List<Number>>assertThat(Collections.<Number>unmodifiableList(CollectionLiterals.<Number>newArrayList(Integer.valueOf(1), Double.valueOf(2.0), Integer.valueOf(3))), CoreMatchers.<Integer>hasItem(Integer.valueOf(5)));");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_21() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import static org.junit.Assert.*");
    _builder.newLine();
    _builder.append("import static org.hamcrest.CoreMatchers.*");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("def void m() {");
    _builder.newLine();
    _builder.append("\t\t");
    _builder.append("assertThat(#{1, 2.0, 3}, hasItem(5))");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("}");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.Set;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.hamcrest.CoreMatchers;");
    _builder_1.newLine();
    _builder_1.append("import org.junit.Assert;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public void m() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("Assert.<Set<Number>>assertThat(Collections.<Number>unmodifiableSet(CollectionLiterals.<Number>newHashSet(Integer.valueOf(1), Double.valueOf(2.0), Integer.valueOf(3))), CoreMatchers.<Integer>hasItem(Integer.valueOf(5)));");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_31() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface A {}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface B extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface C extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<Functions.Function0<?>> x = #[[| null as B],  [| null as C]]");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface B extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface C extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<Function0<?>> x = Collections.<Function0<?>>unmodifiableList(CollectionLiterals.<Function0<?>>newArrayList(new Function0<Object>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Object apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.B) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Object>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Object apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.C) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_32() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface A {}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface B extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface C extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<Functions.Function0<? extends A>> x = #[[| null as B],  [| null as C]]");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface B extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface C extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<Function0<? extends Outer.A>> x = Collections.<Function0<? extends Outer.A>>unmodifiableList(CollectionLiterals.<Function0<? extends Outer.A>>newArrayList(new Function0<Outer.A>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.A apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.B) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Outer.A>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.A apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.C) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_33() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface A {}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface B extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface C extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<? extends Functions.Function0<? extends A>> x = #[[| null as B],  [| null as C]]");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface B extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface C extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<? extends Function0<? extends Outer.A>> x = Collections.<Function0<? extends Outer.A>>unmodifiableList(CollectionLiterals.<Function0<? extends Outer.A>>newArrayList(new Function0<Outer.A>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.A apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.B) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Outer.A>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.A apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.C) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_34() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface A {}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface B extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface C extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<? extends Functions.Function0<A>> x = #[[| null as B],  [| null as C]]");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface B extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface C extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<? extends Function0<Outer.A>> x = Collections.<Function0<Outer.A>>unmodifiableList(CollectionLiterals.<Function0<Outer.A>>newArrayList(new Function0<Outer.A>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.A apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.B) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Outer.A>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.A apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.C) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_35() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.Set");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface A {}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface B extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface C extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val Set<Functions.Function0<? extends A>> x = #{ [| null as B],  [| null as C] }");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.Set;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface B extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface C extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final Set<Function0<? extends Outer.A>> x = Collections.<Function0<? extends Outer.A>>unmodifiableSet(CollectionLiterals.<Function0<? extends Outer.A>>newHashSet(new Function0<Outer.A>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.A apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.B) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Outer.A>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.A apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.C) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_36() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.Set");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface A {}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface B extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface C extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val Set<Functions.Function0<A>> x = #{ [| null as B],  [| null as C] }");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.Set;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface B extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface C extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final Set<Function0<Outer.A>> x = Collections.<Function0<Outer.A>>unmodifiableSet(CollectionLiterals.<Function0<Outer.A>>newHashSet(new Function0<Outer.A>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.A apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.B) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Outer.A>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.A apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.C) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_37() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.Set");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface A {}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface B extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface C extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val Set<? extends Functions.Function0<? extends A>> x = #{ [| null as B],  [| null as C] }");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.Set;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface B extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface C extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final Set<? extends Function0<? extends Outer.A>> x = Collections.<Function0<? extends Outer.A>>unmodifiableSet(CollectionLiterals.<Function0<? extends Outer.A>>newHashSet(new Function0<Outer.A>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.A apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.B) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Outer.A>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.A apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.C) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_38() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.Set");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface A {}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface B extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface C extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val Set<? extends Functions.Function0<A>> x = #{ [| null as B],  [| null as C] }");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.Set;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface B extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface C extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final Set<? extends Function0<Outer.A>> x = Collections.<Function0<Outer.A>>unmodifiableSet(CollectionLiterals.<Function0<Outer.A>>newHashSet(new Function0<Outer.A>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.A apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.B) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Outer.A>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.A apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.C) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_39() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface A {}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface B extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface C extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<Functions.Function0<?>> x = newArrayList([| null as B],  [| null as C])");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface B extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface C extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<Function0<?>> x = CollectionLiterals.<Function0<?>>newArrayList(new Function0<Outer.B>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.B apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.B) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Outer.C>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.C apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.C) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("});");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_40() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface A {}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface B extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface C extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<Functions.Function0<? extends A>> x = newArrayList([| null as B],  [| null as C])");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface B extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface C extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<Function0<? extends Outer.A>> x = CollectionLiterals.<Function0<? extends Outer.A>>newArrayList(new Function0<Outer.B>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.B apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.B) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Outer.C>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.C apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.C) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("});");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_41() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface A {}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface B extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface C extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<? extends Functions.Function0<? extends A>> x = newArrayList([| null as B],  [| null as C])");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface B extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface C extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<? extends Function0<? extends Outer.A>> x = CollectionLiterals.<Function0<? extends Outer.A>>newArrayList(new Function0<Outer.B>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.B apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.B) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Outer.C>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.C apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.C) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("});");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  @Ignore("Would be nice but too much effort ATM")
  public void test_42() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface A {}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface B extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface C extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val List<? extends Functions.Function0<A>> x = newArrayList([| null as B],  [| null as C])");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("IGNORED");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_43() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface A {}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface B extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface C extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val x = #[[| null as B],  [| null as C]]");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.Collections;");
    _builder_1.newLine();
    _builder_1.append("import java.util.List;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface B extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface C extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final List<? extends Function0<? extends Outer.A>> x = Collections.<Function0<? extends Outer.A>>unmodifiableList(CollectionLiterals.<Function0<? extends Outer.A>>newArrayList(new Function0<Outer.B>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.B apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.B) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Outer.C>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.C apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.C) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}));");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }

  @Test
  public void test_44() {
    StringConcatenation _builder = new StringConcatenation();
    _builder.append("import java.util.List");
    _builder.newLine();
    _builder.append("class Outer {");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface A {}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface B extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("interface C extends A{}");
    _builder.newLine();
    _builder.append("\t");
    _builder.append("val x = newArrayList([| null as B],  [| null as C])");
    _builder.newLine();
    _builder.append("}");
    _builder.newLine();
    StringConcatenation _builder_1 = new StringConcatenation();
    _builder_1.append("import java.util.ArrayList;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.CollectionLiterals;");
    _builder_1.newLine();
    _builder_1.append("import org.eclipse.xtext.xbase.lib.Functions.Function0;");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("@SuppressWarnings(\"all\")");
    _builder_1.newLine();
    _builder_1.append("public class Outer {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface B extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("public interface C extends Outer.A {");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("private final ArrayList<Function0<? extends Outer.A>> x = CollectionLiterals.<Function0<? extends Outer.A>>newArrayList(new Function0<Outer.B>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.B apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.B) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("}, new Function0<Outer.C>() {");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("public Outer.C apply() {");
    _builder_1.newLine();
    _builder_1.append("      ");
    _builder_1.append("return ((Outer.C) null);");
    _builder_1.newLine();
    _builder_1.append("    ");
    _builder_1.append("}");
    _builder_1.newLine();
    _builder_1.append("  ");
    _builder_1.append("});");
    _builder_1.newLine();
    _builder_1.append("}");
    _builder_1.newLine();
    this.assertCompilesTo(_builder, _builder_1);
  }
}
